import RPi.GPIO as GPIO
import time

pin = 3

GPIO.setmode(GPIO.BOARD)
GPIO.setup(pin,GPIO.OUT)

p = GPIO.PWM(pin,1000)

p.start(0)
	

j=0
while j<3:
    for i in range(0,100):
        p.ChangeDutyCycle(i)
        print i
        time.sleep(0.02)
    j=j+1

p.stop()
GPIO.cleanup()
